package org.db2.project.airline.model;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import java.io.Serializable;

/**
 * The persistent class for the AIRPORT database table.
 */
@Entity
public class Airport implements Serializable {
    private static final long serialVersionUID = 1L;

    @Id
    @SequenceGenerator(name = "AIRPORT_ID_GENERATOR", sequenceName = "AIRPORT_SEQ")
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "AIRPORT_ID_GENERATOR")
    private long id;

    private long active;

    private String address;

    private String code;

    private String name;

    public Airport() {
    }

    public long getId() {
        return this.id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public long getActive() {
        return this.active;
    }

    public void setActive(long active) {
        this.active = active;
    }

    public String getAddress() {
        return this.address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getCode() {
        return this.code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getName() {
        return this.name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Override
    public String toString() {
        return name;
    }
}